version: "2"
services:
  postgres:
    image: ${POSTGRES_IMAGE}
    volumes:
      - ${DATA}postgres_data:/bitnami/postgresql/data
    environment:
      - POSTGRES_USER=${POSTGRES_USER}
      - POSTGRES_PASSWORD=${POSTGRES_PASSWORD}
  maria:
    image: ${MARIADB_IMAGE}
    volumes:
      - ${DATA}maria_data:/bitnami/mariadb/data
    environment:
      - MARIADB_ROOT_PASSWORD=${MARIADB_ROOT_PASSWORD}
  mongo:
    image: ${MONGO_IMAGE}
    volumes:
      - ${DATA}mongo_data:/bitnami/mongodb/data
  nginx:
    image: ${NGINX_IMAGE}
    ports:
      - 80:80
      - 443:443
    volumes:
      - ${DATA}nginx_data:/var/www/html
#      - ${DATA}nginx_config:/etc/nginx/conf.d/
  pgadmin4:
    image: ${PGADMIN_IMAGE}
    restart: always
    environment:
      - PGADMIN_DEFAULT_EMAIL=${PGADMIN_DEFAULT_EMAIL}
      - PGADMIN_DEFAULT_PASSWORD=${PGADMIN_DEFAULT_PASSWORD}
      - PGADMIN_LISTEN_PORT=${PGADMIN_LISTEN_PORT}
    ports:
      - "5050:8080"
    volumes:
      - ./servers.json:/pgadmin4/servers.json
  ftp:
    image: ${FTP_IMAGE}
    ports:
      - '20-21:20-21/tcp'
      - '40000-40009:40000-40009/tcp' # Only needed for passive mode
    volumes:
      - '${DATA}nginx_data:/home/user'
    environment:
      - FTP_USER=${FTP_USER}
      - FTP_PASS=${FTP_PASS}
  gogs:
    image: ${GOGS_IMAGE}
    ports:
      - "3000:3000"
    volumes:
      - ${DATA}gogs_data:/data